package com.mayikt.pay.jobhandler;

import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
import com.xxl.job.core.log.XxlJobLogger;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.time.LocalDateTime;

@Slf4j
//@Component
public class TestJob {

    @XxlJob(value = "demoJobHandler")
    public ReturnT<String> execute(String param) throws Exception {
        log.info("====>> XXL-JOB, Hello World时间：{}", LocalDateTime.now());
        XxlJobLogger.log("XXL-JOB, Hello World.");
        return ReturnT.SUCCESS;
    }
}
